package com.dbzf.service.impl;

import com.dbzf.dao.StudentDao;
import com.dbzf.dao.impl.StudentDaoImpl;
import com.dbzf.entity.Student;
import com.dbzf.service.StudentService;

import java.util.List;

public class StudentServiceImpl implements StudentService {
    private StudentDao studentDao = new StudentDaoImpl();
    @Override
    public List<Student> getAllStu(Integer currentPage,Integer pageSize) {
        return studentDao.getAllStu(currentPage,pageSize);
    }

    @Override
    public Student getStuByid(Integer id) {
        return studentDao.getStuByid(id);
    }

    @Override
    public int addStu(Student student) {
        return studentDao.addStu(student);
    }

    @Override
    public int deleteStu(Integer sid) {

        return studentDao.deleteStu(sid);
    }

    @Override
    public int updateStu(Student student) {
        return studentDao.updateStu(student);
    }

    @Override
    public int deleteStuMore(String ids) {
        return studentDao.deleteStuMore(ids);
    }

    @Override
    public int getStuCount() {
        return studentDao.getStuCount();
    }
}
